<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"  
    xmlns:h="http://java.sun.com/jsf/html"  
    xmlns:f="http://java.sun.com/jsf/core"  
    xmlns:p="http://primefaces.org/ui">  
  
    <h:head> 
    	<f:facet name="first">
            <meta http-equiv="X-UA-Compatible" content="EmulateIE8" />
            <meta content="text/html; charset=UTF-8" http-equiv="Content-Type"/>
            <title>Locadora - Graph</title>
        </f:facet>
 
        <link type="text/css" rel="stylesheet" href="#{request.contextPath}/resources/telaInicial.css" /> 
        <link type="text/css" rel="stylesheet" href="#{request.contextPath}/resources/cadastroFilme.css" /> 
    	
    </h:head>  
      
    <h:body style="background:black;">
  	 	
    <p:layout fullPage="true">  
    <p:ajax event="toggle"  />  
    <p:ajax event="close"  />  
  
    <p:layoutUnit position="north" size="100"  resizable="true" closable="false" collapsible="false" style="overflow:hidden;min-width:400px;min-height:150px;">  
       <h:form> 
         <p:toolbar style="height:23px;">  
			    <p:toolbarGroup align="right" style="height:18px;">      
				  <p:menubar align="right" style="height:18px;">        
				      <p:menuitem value="Sair" url="../index.xhtml" icon="ui-icon-close" />  
	  			  </p:menubar>  
	  			  
			    </p:toolbarGroup> 
			    <p:toolbarGroup align="left" style="height:18px;">      
				  <p:menubar align="right" style="height:18px;">        
				      <p:menuitem value="Home" url="locadora.xhtml"  />  
	  			  </p:menubar>  
	  			  
			    </p:toolbarGroup>     
  	   </p:toolbar> 
        <center><h:graphicImage  value="#{resource['img:logograph_banner.png']}" /></center>
  </h:form>
  <h:outputText value="#{userBean.sessionUser}" /> 
    </p:layoutUnit>  
  
   
  
    <p:layoutUnit position="west" size="200" style="display:none !important;" resizable="true" closable="true" collapsible="true">  
       
    </p:layoutUnit>  
  
   
  
    <p:layoutUnit position="center"> 
       
    <p:tabView id="tabView" dynamic="true" cache="true">  
  
        <p:tab id="tba1" title="Inicial">  
        <h:form>
            <h:panelGrid columns="2" cellpadding="10">  
                  
          <p:outputLabel>Titulo</p:outputLabel>
         <h:outputText value="#{userBean.movieSelected.title}" /> 
          <p:outputLabel>Genero</p:outputLabel>
         <h:outputText value="#{userBean.movieSelected.gender}" /> 
          <p:outputLabel>Ano de Lançamento</p:outputLabel> 
        <h:outputText value="#{userBean.movieSelected.year}" /> 
         <p:outputLabel>Diretor</p:outputLabel> 
        <h:outputText value="#{userBean.movieSelected.director}" /> 
        <p:outputLabel>Sinopse</p:outputLabel> 
        <h:outputText value="#{userBean.movieSelected.sinopse}" />   
        
        
         <p:commandButton actionListener="#{userBean.alugaFilme}" value="Alugar"  ajax="false"></p:commandButton>
            </h:panelGrid>  
        </h:form>
        </p:tab>  
  
    </p:tabView>  
    </p:layoutUnit>  
  
</p:layout>  
                              
    </h:body>  
</html>  